package devTest 
{
	import flash.display.Sprite;
	import flash.geom.Point;
	/**
	 * ...
	 * @author miquel
	 */
	public class CSpriteMovement extends Sprite
	{
		//pressing keys
		protected var pressUp:			Boolean	= false;
		protected var pressDown:		Boolean	= false;
		protected var pressLeft:		Boolean	= false;
		protected var pressRight:		Boolean	= false;
		
		protected var m_v2Direction:	Point 	= null;		//x, y vector for apply to ball movement
		protected var m_iSpeed:			int 	= 0;		
		

		/**
		 * constructor: 
		 */
		public function CSpriteMovement() 
		{
			
		}
		
		/**
		 * ReadXMLValues: 
		 * @param : the treenode xml
		 */
		public function ReadXMLValues(_node:XML):void
		{
			//read xml values
			x 		 		= _node.@x;
			y 		 		= _node.@y;
			m_iSpeed 		= _node.@speed;
		}


		/**
		 * InitVector: reset the director vector
		 */
		public function InitVector():void 
		{
			if (m_v2Direction != null)
			{
				trace("init vector director");
				m_v2Direction.x = 0;
				m_v2Direction.y = 0;
			}
		}

		
		/**
		 * Move: Movement basics
		 */
		public function Move():int
		{
			return 0;
		}
		
	}

}